package com.controller.seedoctor;

import io.swagger.annotations.*;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.sql.Timestamp;

@RestController
@RequestMapping("/seeDoctor")
@Api(value = "看病就诊模块",tags = "门诊挂号接口")
public class ConsultingController {
    //查询患者库患者信息

        @GetMapping("/consulting/queryPa")
        @ApiOperation(value = "查询患者库患者信息", notes = "查询患者库患者信息")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "CurrentPage", value = "当前页码数", paramType = "query", dataType = "Integer", required = true),
                @ApiImplicitParam(name = "PageSize", value = "每行显示记录数", paramType = "query", dataType = "Integer", required = true),
                @ApiImplicitParam(name = "bank_name", value = "患者姓名", paramType = "query", dataType = "String", required = true)
        })
        public String queryPa(@ApiParam() Integer CurrentPage, Integer PageSize, String bank_name) {

            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";


        }


    //查询正在上班的医生名单

        @GetMapping("/consulting/register")
        @ApiOperation(value = "门诊挂号，查询按钮接口", notes = "查询正在上班的医生名单")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "CurrentPage", value = "当前页码数", paramType = "query", dataType = "Integer", required = true),
                @ApiImplicitParam(name = "PageSize", value = "每行显示记录数", paramType = "query", dataType = "Integer", required = true),
                @ApiImplicitParam(name = "department", value = "科室名称", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "doctor", value = "医生姓名", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "reg_type", value = "挂号类型", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "reg_time", value = "挂号日期", paramType = "query", dataType = "Timestamp", required = true)
        })
        public String queryConsulting(@ApiParam() Integer CurrentPage, Integer PageSize, String department, String doctor, String reg_type, Timestamp reg_time) {
            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";

        }

    //提交相关患者，医生信息并进行收费

        @PostMapping("/consulting/submitConsulting")
        @ApiOperation(value = "门诊挂号,缴费提交按钮接口", notes = "提交相关患者，医生信息并进行收费")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "reg_fees", value = "挂号费", paramType = "query", dataType = "decimal", required = true),
                @ApiImplicitParam(name = "bank_name", value = "患者姓名", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "sex", value = "性别", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "birthday", value = "生日", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "phone", value = "手机号", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "id_number", value = "身份证", paramType = "query", dataType = "String", required = true),
                @ApiImplicitParam(name = "right_vision", value = "住址", paramType = "query", dataType = "String", required = true)
        })
        public String submitConsulting(@ApiParam() double reg_fees, String bank_name, String sex, String birthday, String doctor, String phone,String id_number,String right_vision) {

            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";

        }

    //查询科室信息（下拉框）

        @GetMapping("/consulting/querydm")
        @ApiOperation(value = "查询全部科室名称", notes = "查询全部科室名称")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "department", value = "科室名称", paramType = "query", dataType = "String", required = true),
        })
        public String querydm(@ApiParam() String department) {
            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";

        }

    //查询全部医生姓名（下拉框）

        @GetMapping("/consulting/queryDoctor")
        @ApiOperation(value = "查询全部医生姓名", notes = "查询全部医生姓名")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "doctor", value = "医生姓名", paramType = "query", dataType = "String", required = true),
        })
        public String queryDoctor(@ApiParam() String doctor) {
            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";

        }

    //查询挂号信息（下拉框）

        @GetMapping("/consulting/queryReq ")
        @ApiOperation(value = "查询全部挂号类型", notes = "查询全部挂号类型")
        @ApiImplicitParams({
                @ApiImplicitParam(name = "reg_type_id", value = "挂号类型", paramType = "query", dataType = "String", required = true),
        })
        public String queryReq(@ApiParam() String reg_type_id) {
            return "{\n" +
                    "\t\"code\": 200,\n" +
                    "\t\"msg\": \"成功！\",\n" +
                    "\t\"data\": []\n" +
                    "}"+
                    "{\n" +
                    "\t\"code\": 500,\n" +
                    "\t\"msg\": \"服务器开小差！\",\n" +
                    "\t\"data\": []\n" +
                    "}";

        }
    }

